package com.itheima.edu.info.manager.day7;

import java.util.ArrayList;
import java.util.Collection;

public class StudentTest {
    public static void main(String[] args) {
        Collection<Student> collection = new ArrayList<>();
        Student st=new Student();
        Student st3=new Student();
        Student st1=new Student();
        st.setName("王五");
        st.setAge(19);
        st1.setName("张三");
        st1.setAge(18);
        st3.setName("李七");
        st3.setAge(20);
        collection.add(st);
        collection.add(st1);
        collection.add(st3);
        for (Student student : collection) {
            System.out.println(student);
        }
    }

}
